/*
 * Created on2022/6/11 18:22
 *
 * Copyright(c) YuZhou Big Data Laboratory CO.,Ltd, 2022.  All rights reserved.
 *
 *******************************************************************************
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with
 * the License. You may obtain a copy of the License at
 *
 *    http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 *
 ******************************************************************************/

package org.yzbdl.lanius.core.plugins.metastore;

import java.util.Date;

import javax.persistence.*;

import org.yzbdl.lanius.core.metastore.BaseEntity;

/**
 * 核心对象树插件与分组、分类的关联关系信息
 *
 * @author hs@yzbdl.ac.cn
 * @version 1.0
 * @date 2019/6/11 18:22
 */
@Entity
@Table(name = "ldr_plugin_category")
public class LdrPluginCategoryEntity extends BaseEntity {

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Column(name = "id")
    private Integer id;

    /**
     * 所属分组ID
     */
    @Column(name = "category_id")
    private Integer categoryId;

    /**
     * 插件ID
     */
    @Column(name = "plugin_id")
    private Integer pluginId;

    /**
     * 创建时间
     */
    @Column(name = "create_time")
    private Date createTime = new Date();

    public LdrPluginCategoryEntity() {}

    public LdrPluginCategoryEntity(Integer id) {
        this.id = id;
    }

    public LdrPluginCategoryEntity(Integer pluginId, Integer categoryId) {
        this.pluginId = pluginId;
        this.categoryId = categoryId;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getPluginId() {
        return pluginId;
    }

    public void setPluginId(Integer pluginId) {
        this.pluginId = pluginId;
    }

    public Integer getCategoryId() {
        return categoryId;
    }

    public void setCategoryId(Integer categoryId) {
        this.categoryId = categoryId;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
}
